package cn.qingyun.gis.modules.scenes.contant;

public enum TypeStatus {
    /**
     * 场景类型枚举
     */
    PHOTO("photo"),
    AUDIO("audio"),
    TEXT("text");


    private final String desc;

    TypeStatus(String desc) {
        this.desc = desc;
    }

    public String getDesc() {
        return desc;
    }

    public static TypeStatus fromDescription(String description) {
        for (TypeStatus status : values()) {
            if (status.getDesc().equals(description)) {
                return status;
            }
        }
        throw new IllegalArgumentException("未知的状态描述：" + description);
    }
}
